package com.lzp.entity;

import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;

import java.io.Serializable;

/**
 * Created by liuzp on 2017/11/23.
 */
@Document(collection = "user")//指定表名
public class User implements Serializable{

    private static final long serialVersionUID = 1L;

    @Id
    private String id;//对应Mongodb主键_id

    private String userName;

    private String passWd;

    public User(String userName,String passWd){
        this.userName = userName;
        this.passWd = passWd;
    }

    public User(){

    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getPassWd() {
        return passWd;
    }

    public void setPassWd(String passWd) {
        this.passWd = passWd;
    }
}
